home *** CD-ROM | disk | FTP | other *** search
/ Macworld Expo - Develope…Central & Net Innovations / Developer Central and Net Innovators (MacWorld Expo) (January 1999).iso / Developer Central / Metrowerks CodeWarrior / CodeWarrior Pro 4 Release Notes / Libraries Notes / MSL Release Notes / MSL 4.0.10 Release Notes (Pro4) < prev   
Encoding:
Text File  |  1998-08-31  |  38.2 KB  |  1,095 lines  |  [TEXT/CWIE]

  1. ========================================================================
  2. Metrowerks MSL 4.0.10 Pro4 Final Candidate 2 Release Notes 
  3. ========================================================================
  4.  
  5. Version: Metrowerks CodeWarrior 4.0.9 MSL Pro4 FC2
  6. Date:    August 26, 1998
  7. Authors: Vicki Scott, Michael Marcotty, Matt Fassiotto, Ron Liechty,
  8.          Howard Hinnant 
  9.                   
  10. ========================================================================
  11.  
  12. ========================================================================
  13. New Features in This Version
  14. ========================================================================
  15.  
  16. *  __MSL__ identifier is 0x4010.  This release is known as the Pro4
  17.    Final Candidate 2.  This number identifies MSL as Pro 4 (major 
  18.    release number), Patch 0 (minor release number), build 10.  We've 
  19.    had a few requests for making this number look more like it sounds, 
  20.    so although it is increasing with each build, it isn't necessarily 
  21.    monatomically increasing (i.e., build 10 looks like the decimal
  22.    number 10 instead of the hexadecimal value of "a").
  23.    
  24. *  Member templates have been implemented in the library.  This has
  25.    been validated with a standard test suite, but has not been
  26.    exercised in the many ways that application programs devise.
  27.    If you are experiencing problems with member templates and you
  28.    suspect the library, you can disable this feature in mcompile.h 
  29.    (comment out the line #define MSIPL_MEMBER_TEMPLATE).  Refer to 
  30.    the notes below on functions that are still not working with 
  31.    member templates.
  32.  
  33. *  __MSL_FIX_ITERATORS__ has been removed!  The compiler now fixes
  34.    partial template specializations (be sure and read the compiler
  35.    release notes for restrictions, however).  This means you no longer
  36.    need this hack in your code anymore.  See notes below for how to
  37.    remove this from your code - there is a trick that you have to be 
  38.    aware of.
  39.    
  40. *  <locale> has been completely rewritten to improve speed and size
  41.    of compilation.  See notes below for variances from the Standard.
  42.    
  43. *  The slist class has been fixed.
  44.  
  45. *  The hash class functions are available, but not fully supported in 
  46.    this release.
  47.  
  48. *  <bitset> now uses only one bit per bool instead of one byte
  49.  
  50. *  <algorithm> has been rewritten to fix quite a few bugs and some
  51.    gain in performance and correctness of functions
  52.    
  53. *  mem_fun classes now implemented
  54.  
  55. *  Math functionality includes improved cross-platform support for the 
  56.    most common functions.  The biggest feature in the math support 
  57.    includes the ability to call math functions through a function 
  58.    pointer in both C and C++ and on all supported platforms.  See the
  59.    notes below on math features for additional information.
  60.  
  61.    New functions on Intel include nan("char* tagp") and the C9X 
  62.    relational macros, isgreater,isless, etc...
  63.    
  64.  
  65. ========================================================================
  66. Reported Bugs Fixed in This Version
  67. ========================================================================
  68.  
  69. *  MW00042 (Mac)
  70.    The definition of O_RDWR in the ANSI header fcntl.h is now defined as 
  71.    0x01, instead of 0x0. 
  72.                               
  73. *  MW00225 (Mac)
  74.    Fixes the inadvertent release of a shared resource prior to when it 
  75.    should be released.
  76.  
  77. *  MW00288 (x86)
  78.    Fixes a problem with exit code on Windows' platforms. 
  79.  
  80. *  MW00294 (Mac)
  81.    Fixes a problem following aliases
  82.  
  83. *  MW00427 
  84.    Fixes specializations in valarray
  85.  
  86. *  MW00445 (Mac, x86 still needs to be fixed)
  87.    Fixes a problem with trying to seek past EOF
  88.  
  89. *  MW00456 (Mac)
  90.    Fixes a problem with renaming directories
  91.  
  92. *  MW01597 (x86)
  93.    Fixes a problem with renaming "open" to "_open"
  94.  
  95. *  MW01813 (Mac/PPC)
  96.    Fixes a one-off bug in strstr when null is part of the pattern 
  97.  
  98. *  MW02103
  99.    MW06325
  100.    The speed and size requirements (too slow, too big) have been fixed
  101.    in <locale> in the C++ library.  It no longer takes >64K memory nor 
  102.    half and hour to compile locimp.cpp  
  103.  
  104. *  MW02520
  105.    Fixes string I/O alignment in C++ 
  106.    
  107. *  MW02557
  108.    removed the Win32 SDK header x86_prefix.h from MSL.  We now 
  109.    use the one provided with the SDK.
  110.                 
  111. *  MW02625
  112.    Fixes a problem with memchr and __memrchr for characters > 0x80
  113.  
  114. *  MW02733
  115.    Fixes a problem with state bit when fflush is called 
  116.    
  117. *  MW02910
  118.    Fixes character output alignment in C++
  119.  
  120. *  MW03236
  121.    Fixes the search algorithm in <algorithm> to be more efficient 
  122.    
  123. *  MW03272 
  124.    Fixes a bug in fread when a file contains fewer bytes than
  125.    requested
  126.   
  127. *  MW03278 (mac)
  128.    Fixes a cosmetic bug in SIOUX
  129.  
  130. *  MW03295 (mac)
  131.    Fixes a bug in FSp_fopen with _fcreator and _ftype
  132.  
  133. *  MW05946
  134.    Fixes a bug in getting memory for a error warning during 
  135.    an exception
  136.  
  137. *  MW06295
  138.    Fixes bug when trying to print a long long cast to an int
  139.  
  140. *  MW06496
  141.    Fixes a bug with strftime incorrectly returning zero 
  142.  
  143. *  MW06626
  144.    Fixes a bug in setw when temporary string is destructed 
  145.    leaving a dangling pointer
  146.  
  147. *  MW07009 (x86)
  148.    Fixes a bug in WinSIOUX when passing arguments to main 
  149.  
  150. *  MW07031
  151.    Fixes a bug in SIOUX WASTE with data type too small for 
  152.    possible values
  153.    
  154. *  unix headers stat.h/fcntl.h/unistd.h were not including the 
  155.    correct version header file because __dest_os was not defined.
  156.    
  157. *  Fixed the problem with OLDROUTINENAMES define
  158.  
  159. *  Fixed the problem with std:: in size_t and offsetof macros
  160.  
  161. *  Fixed problem with POSIX definition of fdopen
  162.  
  163. *  Fixed open flags for win32 files to not truncate files when opening 
  164.  
  165. *  Fixed project files for x86 to include the relative path names
  166.  
  167. *  Added the "sys" directory and moved stat.h to it so that x86 files
  168.    who look for <sys\stat.h> can now find it.  This is ugly, but we 
  169.    will be rearranging the directory structure in the future to 
  170.    accommodate additional platforms and will get this cleaned up at 
  171.    a later date.
  172.    
  173. *  Moved stroul syntax and stroud syntax files to a new folder called
  174.    "MSL Technical Notes" and restored their contents (missing since
  175.    Pro 1)
  176.    
  177. *  Fixed SIOUX project files on Mac to not include the prefix file 
  178.  
  179.            
  180. ==============================================================   
  181. Math bugs fixed in this release
  182. ==============================================================  
  183.     
  184. *  MW01298
  185.    __float_min etc. have been removed from float.c.  Standard 
  186.    constants such as FLT_MIN,FLT_MAX are now translated by the 
  187.    compiler at compile time.
  188.    
  189. *  MW02445
  190. *  MW01261
  191.    precision of printing doubles was incorrect even when values 
  192.    are exact(e.g., ints).  the module ansi_fpx86.obj replaces
  193.    ansi_fp_x86.c on INTEL.
  194.              
  195. *  MW07091
  196.    could not reproduce this, but the implementation of complex 
  197.    log10 was inefficient.  We now multiply by a constant instead
  198.    of a function call/divide.  this should be fixed.
  199.  
  200. *  fmin/fmax/fdim
  201.    now are strictly compliant with C9X
  202.  
  203. *  complex abs/sqrt
  204.    were not working for large values or values near 0.
  205.    using hypot instead of sqrt(x*x + y*y).
  206.    
  207. *  MW07513
  208.    long double math functions do not work on PPC. The problem
  209.    was that prototypes instead of macros sere in cmath.  We do 
  210.    not support the 128 bit long double data type on the PPC,
  211.    so the return values of these functions will not properly
  212.    coerce into IEEE 64 bit doubles.              
  213.              
  214. *  MW02614/MW02687/MW01266 
  215.    on 68K for 8 byte doubles, functions pointers to
  216.    ANSI math functions now work.
  217.  
  218.    
  219. *  MW02914/MW06751 
  220.    math.h/fp.h conflicts on 68K when including HyperXcmd.h
  221.    (In general, math.h and fp.h conflict on 68K).  This is
  222.    fixed as best as it can be.  There are two known minor 
  223.    problems remaining.  If including cmath first no problems
  224.    exist.  If including fp.h first then there are two 
  225.    known incompatibilities:
  226.    
  227.    a. When the C++ compiler is on, you cannot call std::foo
  228.       directly in the including program(foo is any standard
  229.       math function).
  230.       
  231.    b. On 68K only, you cannot assign the address of one of 
  232.       the math functions to a double function pointer.  The
  233.       reason for this is that the prototypes in fp.h are 
  234.       picked up first and are all of type long double.
  235.       A work around to this is to turn on "relaxed pointer
  236.       types" in the C++ Language pref panel.
  237.     
  238.   See MSL tech notes for additional information on this issue
  239.                 
  240. ==============================================================   
  241. The following user reported bugs were fixed in Pro3, but were 
  242. not mentioned in the Pro3 Release Notes:
  243. ==============================================================  
  244.  
  245. *  MW01251
  246.    fabs crashes under CFM-68K
  247.    
  248. *  MW00102
  249.    SIOUXSetTitle
  250.  
  251. *  MW00222
  252.    gratuitous warning messages
  253.    
  254. *  MW00319  
  255.    memory leaks in streams
  256.    
  257. *  MW00376
  258.    exception safe uninitialized_fill
  259.          
  260. *  MW00427
  261.    MW02709
  262.    MW02789
  263.    brain dead valarray 
  264.    
  265. *  MW00451
  266.    string exposed refcounted implementation
  267.      
  268. *  MW00593
  269.    mutable bug in auto_ptr
  270.    
  271. *  MW00622
  272.    sputbackc
  273.   
  274. *  MW00767
  275.    string::operator[] fixed
  276.    
  277. *  MW00805
  278.    exception safety of entire lib, esp. vector::op=
  279.    
  280. *  MW00827
  281.    explicit facet constructor
  282.    
  283. *  MW01254
  284.    problem with vector.h --> insert
  285.    
  286. *  MW01279
  287.    what() in exception is redeclared 
  288.    
  289. *  MW01300
  290.    mode_t defined twice
  291.    
  292. *  MW01321
  293.    fseek and DOS line endings
  294.  
  295. *  MW02075
  296.    problem with first arg to multimap being const
  297.    
  298. *  MW02345
  299.    better <limits>
  300.       
  301. *  MW02522
  302.    destructor problems for const objects in vector
  303.    
  304. *  MW02531
  305.    string::find
  306.  
  307. *  MW02729
  308.    headers don't pass check syntax
  309.    
  310. *  MW02783
  311.    isnan macro bug 
  312.                
  313. *  MW02848
  314.    bug in hash_table::iterator::operator =()
  315.    
  316. *  MW02948
  317.    abs added to cmath    
  318.    
  319. *  MW02949
  320.    missing size() in valarray
  321.       
  322. *  MW02964
  323.    missing wchar functions
  324.    
  325. *  MW03156
  326.    poor bad_alloc design
  327.    
  328. *  MW03455
  329.    missing operator-> on iterators
  330.    
  331. *  MW05605
  332.    incorrect complex::atan2
  333.    
  334. *  MW05846
  335.    printing \r
  336.    
  337. *  MW05968
  338.    problem in map.h trying to access deallocated memory 
  339.    
  340. *  MW06626
  341.    a locale problem
  342.   
  343.      
  344. ========================================================================
  345. Known Bugs and Incompatibilities
  346. ========================================================================
  347.  
  348. *  multibyte routines not implemented 
  349.  
  350. *  wide character support in C++ is unsupported in this release
  351.    
  352. *  MW02521 (mac)
  353.    Conflict with order of includes for Types.h and mcompile.h
  354.  
  355. *  MW02761 (x86)
  356.    Problem with _access if path is a directory
  357.  
  358. *  MW03025 (mac)
  359.    SIOUX WASTE project file needs addition settings to build optimally 
  360.  
  361.  
  362. *  MW03454/MW05701 
  363.    strtod/sscanf produce results off by a factor of 10 
  364.    on only 68K.  This only occurs when requesting more
  365.    digits than are guaranteed by the given precision.
  366.    (17 for double, 21 for long double.  using a format
  367.    specifier such as %20.18e for a double will produce
  368.    this error).
  369.    
  370. *  MW07337
  371.    feature not yet added. standard api's atof() and sscanf do 
  372.    not yet implement the C9X extension which requires these
  373.    to recognize the strings NAN and INF as input values.
  374.    we do however have the nan("char tagp") function available
  375.    cross platform .
  376.    
  377. *  signbit(1.0) returns 1 on 68K it should return 0.
  378. *  nan("1234")=nan("6789") on PPC.  Will be reported to Apple.
  379.              
  380.  
  381. ========================================================================
  382. Additional Notes
  383. ========================================================================
  384.  
  385. Disclaimer:
  386.  
  387. This library represents a major step forward in providing fully Standard
  388. compliant C and C++ libraries.  We strongly desire to be responsive to
  389. users' requests and needs; however, our position is that we uphold and
  390. implement the Standards behavior in both the C and C++ libraries.  If a
  391. behavior was provided by MSL but goes against the Standard, we reserve
  392. the right to modify the behavior to comply fully with the Standard.  If,
  393. however, a behavior is unspecified or not specifically forbidden by the
  394. Standard, we will continue to support it in the library.  We reserve the 
  395. right to use our discretion in implementing non-standard and 
  396. non-specified C and C++ library behavior.
  397.  
  398. ===================================================================
  399. *  C++ Library Update
  400. ===================================================================
  401.  
  402.  
  403. General Comments
  404. ----------------
  405.  
  406. The battle with overly used inline continues.  Much of the library has
  407. been fixed in this respect, but there is still a ways to go.
  408.  
  409. Fixing the implicit conversion warnings continues.  Much progress
  410. has been made, but there is still more work to do.
  411.  
  412. Hash Functions
  413. --------------
  414.  
  415. This section of the library remains experimental at this point.  
  416. Hash containers are for thrill seekers only, but please report any 
  417. discrepancies or bugs you find.
  418.  
  419. Member Templates
  420. ----------------
  421.  
  422. This library now supports member templates in a limited way.  The 
  423. advantage to using member templates in the library is that you now 
  424. have the ability to provide your own allocator.  However, a few
  425. functions still will not have member template support in this 
  426. release:
  427.  
  428.    *  auto_ptr  You cannot convert auto_ptr<X> to auto_ptr<Y>
  429.    *  bitset    You cannot convert between bitset and 
  430.                 basic_string<wchar>
  431.                 
  432. Please refer to the compiler notes for the implementation of your own 
  433. member templates.  The member template definition for Pro4 must appear
  434. in the class declaration, but it will only be inlined if the inline
  435. keyword appears with the member template definition. 
  436.  
  437. <algorithm>
  438. -----------
  439.  
  440. The implementation of many methods has been simplified without
  441. changing the actual algorithms used.  Inline depth has been reduced,
  442. and readability increased.
  443.  
  444. Several methods used operator!= on their template parameters.  This bug
  445. has been corrected to use operator== instead.  Affected methods include:
  446. find, search, search_n, remove_copy and unique_copy.
  447.  
  448. An algorithmic bug was fixed in find_end.
  449.  
  450. Return type of generate_n changed from OutputIterator to void in
  451. compliance with the standard.
  452.  
  453. reverse algorithm changed to that suggested by the standard.
  454.  
  455. Added a random access iterator specialization to partition.
  456.  
  457. Added exception safety to stable_partition.
  458.  
  459. Rewrote sort to simplify and achieve a 10% to 15% speed increase.
  460.  
  461. Rewrote stable_sort.  It now is exception safe and gets the right
  462. answer.
  463.  
  464. Rewrote the heap functions for a modest performance improvement.
  465.  
  466. <bitset>
  467. --------
  468.  
  469. Rewrote class to only use 1 bit per bool, as opposed to 1 byte as
  470. implemented previously.
  471.  
  472. <complex>
  473. ---------
  474.  
  475. The multiply and divide operators will now propagate infinities in the
  476. spirit of the C9X draft standard.  Also, in the spirit of C9X, the
  477. simpler functions for multiply and divide can be used by #defining
  478. _MSL_CX_LIMITED_RANGE and recompiling the C++ lib.
  479.  
  480. Attention has been paid to have complex behave better when T is a
  481. user-supplied class rather than float, double and long double.  In
  482. some places, specializations have been implemented so that efficiencies
  483. are not lost when T is a built-in floating point however.
  484.  
  485. <fstream>
  486. ---------
  487.  
  488. Minor changes in the construction of the fstream classes which removes
  489. duplicated work, and eliminates a memory leak.
  490.  
  491. <functional>
  492. ------------
  493.  
  494. Simplified implementation of the arithmetic, comparison and logical
  495. operators to increase readability.
  496.  
  497. Rewrote mem_fun classes and functions.
  498.  
  499. <ios>
  500. -----
  501.  
  502. Altered ios_base in such a way that its default constructor does not
  503. touch any memory.  This is key in getting the standard streams (cin,
  504. cout, etc.) to be functional before and after main, and at the same
  505. time, not leak memory.
  506.  
  507. Modified the default constructor of basic_ios for the same reasons as
  508. mentioned above for ios_base.
  509.  
  510. Added a _SaveFlags class that saves the flags of a ios_base.  This is
  511. used in <locale> to temporarily change the flags of a stream in an
  512. exception safe manner.
  513.  
  514. <iostream>
  515. ----------
  516.  
  517. Put the static ios_base::Init object back in this header (it was
  518. removed from here in Pro3).  It was moved out to help stop a memory leak
  519. associated with the standard streams.  The stream classes have been
  520. modified now to not leak, even with the Init object back in this
  521. header.  Having the Init object in this header is key to getting the
  522. standard streams to be functional before and after main.
  523.  
  524. <istream>
  525. ---------
  526.  
  527. Removed #include <extmath.h>.  It was not needed, and was causing a
  528. conflict with assert.
  529.  
  530. A default constructor was added to aid in the construction of the
  531. standard streams in a non-leaking manner.
  532.  
  533. Corrected the basic_istream constructor which takes a streambuf
  534. pointer.  This not only made the class more standard, but corrected a
  535. problem with user-defined classes derived from istream.
  536.  
  537. basic_iostream constructor modified so that ios_base::init() is called
  538. only once.  This stops a memory leak.
  539.  
  540. <iterator>
  541. ----------
  542.  
  543. Added a standard partial specialization to iterator_traits:
  544. template <class T> struct iterator_traits <const T*>
  545.  
  546. Added the macro #define __MSL_FIX_ITERATORS__(myType) for when
  547. MSIPL_PARTIAL_SPECIALIZATION is defined (partial template
  548. specialization support).  This macro is meant to define away code
  549. which was previously needed to work around lack of partial template
  550. specialization support.  Unfortunately the old __MSL_FIX_ITERATORS__
  551. macro did not include a trailing ';', thus forcing users to add one.
  552. Now when MSIPL_PARTIAL_SPECIALIZATION is turned on, the trailing ';'
  553. that users had to add will still be there, possibly in a place that
  554. the compiler doesn't appreciate.  Such ';' must be manually deleted
  555. by the user at each use.  The version of the  __MSL_FIX_ITERATORS__
  556. macro that is active when MSIPL_PARTIAL_SPECIALIZATION is not defined
  557. has been modified to include the trailing ';'.  Thus, once the user
  558. removes the trailing ';' from each use of the __MSL_FIX_ITERATORS__
  559. macro, MSIPL_PARTIAL_SPECIALIZATION can be turned on and off with
  560. ease.  Sorry for the inconvenience.
  561.  
  562. To summarize, in your code change
  563. __MSL_FIX_ITERATORS__(MyClass);
  564. to
  565. __MSL_FIX_ITERATORS__(MyClass)
  566.  
  567. This macro will not be required for your classes with partial template
  568. compiler support.  At the time of this writing, it is not certain if
  569. new compilers will be released simultaneously with this library.
  570.  
  571. The distance() method has been simplified.
  572.  
  573. reverse_iterator was rewritten without mutex.  mutex is too expensive
  574. to burden such a light weight object with.  reverse_iterators passed
  575. by value to multiple threads will maintain their integrity.  However,
  576. the object that they refer to will have to be properly mutex'ed by the
  577. user.  This design insures that you only pay for mutex when you need
  578. it.
  579.  
  580. Rewrote istream_iterator for several reasons:  1.  It mistakenly
  581. referred to cin.  2.  It had a mutex object.  3.  It had a bool data
  582. member that was unnecessary (this should be a very light weight
  583. object).
  584.  
  585. Removed copy constructor and destructor from ostream_iterator.  The
  586. compiler generated versions work just fine, and the result is a class
  587. that the compiler has an easier time inlining.
  588.  
  589. Rewrote istreambuf_iterator for modest performance gains.
  590.  
  591. <limits>
  592. --------
  593.  
  594. Changed #include <wchar.h> to <cwchar>.  Silly bug!
  595.  
  596. Removed previous implementation which was in comments.
  597.  
  598. <locale>
  599. --------
  600.  
  601. Rewrote.  The new version fixes many bugs.  Most notably, the C++
  602. library will now compile with much less ram and cpu.
  603.  
  604. There is a performance / functionality tradeoff that can be controlled
  605. by the user via #define flags in <mcompile.h>.  The tradeoff stems
  606. from the fact that most of the code in <locale> lives under templated
  607. virtual methods.  With current compiler technology, templates with
  608. virtual methods are completely instantiated if an instance of that
  609. class template is constructed.  This adds up to a lot of code that is
  610. instantiated, but will often never be used.
  611.  
  612. Metrowerks is working on both library and compiler technology to
  613. optimize away this problem.  In the mean-time we offer some low-tech
  614. options to save both code size, and library compile time:
  615.  
  616. The virtual key word can be easily turned on and off for each
  617. individual facet class in <locale>.  When all facets have virtual
  618. methods, this is standard.  Turning off the virtualness of a facet's
  619. methods means that you will not be able to derive from a facet and
  620. thus alter I/O behavior.
  621.  
  622. There is a group of facets that have "punct" in their name:
  623. numpunct, moneypunct, and timepunct (timepunct is non-standard).
  624. These facets are very small (in code), but offer tremendous
  625. flexibility in the customization of I/O.  With these classes one can
  626. alter the placement of commas for grouping digits (thousands
  627. separators), or even change what character is used.  The decimal point
  628. character can also be modified.  Even the character strings that
  629. represent true and false can be changed.
  630.  
  631. A good performance / functionality tradeoff is to make only the
  632. "punct" facets virtual.  This can easily be done by
  633.     #define _ONLY_VIRTUAL_PUNCTS
  634. in <mcompile.h>.  In fact this is the default state of the C++ libs
  635. that we will ship.
  636.  
  637. Also in <mcompile.h> you will notice two other
  638. flags that are commented out:
  639. //    #define _NO_VIRTUAL_FACETS
  640. //    #define _CUSTOM_VIRTUAL_FACETS
  641.  
  642. If you wish no facets to have virtual methods, then comment out
  643. _ONLY_VIRTUAL_PUNCTS, and uncomment _NO_VIRTUAL_FACETS.
  644.  
  645. If you with to define precisely which facets have virtual methods then
  646. use the _CUSTOM_VIRTUAL_FACETS flag, and then modify <locale> at line
  647. 71 to specify which facets you want virtual methods turned off.  The
  648. macro magic there ought to be clear for those wishing to travel down
  649. this road.
  650.  
  651. For a completely standard lib (all facets have virtual methods) then
  652. comment out all three flags (_ONLY_VIRTUAL_PUNCTS, _NO_VIRTUAL_FACETS
  653. and _CUSTOM_VIRTUAL_FACETS) in <mcompile.h>.
  654.  
  655. As mentioned above, a non-standard class has been added:
  656.  
  657. template <class charT>
  658. class timepunct
  659.     : public locale::facet
  660. {
  661. public:
  662.     explicit timepunct(size_t refs = 0);
  663.     const charT* weekday_name(size_t d) const;
  664.     const charT* month_name(size_t m) const;
  665.     const charT* am_pm(int hour) const;
  666. protected:
  667.     timepunct();
  668.     virtual const charT* do_weekday_name(size_t d) const;
  669.     virtual const charT* do_month_name(size_t m) const;
  670.     virtual const charT* do_am_pm(int hour) const;
  671. };
  672.  
  673. This class can be overridden so that the standard time_put and
  674. time_get work with user defined character strings to represent the
  675. names of the months (which default to "January", "February", ...),
  676. the days of the week (which default to "Sunday", "Monday", ...), and
  677. the am/pm designator (which defaults to "am", "pm").
  678.  
  679. To create your own timepunct class you must derive it from
  680. std::template <class charT> class _Generic_timepunct.  I recommend
  681. that you copy the implementation for template <> class
  682. timepunct<char>.
  683.  
  684. <mcompile.h>
  685. ------------
  686.  
  687. In addition to the flags mentioned under locale section, the flag
  688. MSIPL_PARTIAL_SPECIALIZATION has been added.  This flag controls
  689. whether or not the library is expecting the compiler to support
  690. partial template specialization.
  691.  
  692. The flag _WIN32 has been added to the Windows platform.
  693.  
  694. The macro MSIPLSTD was changed from std to  ::std.
  695.  
  696. <memory>
  697. --------
  698.  
  699. get_temporary_buffer was rewritten.  It used to use a preallocated
  700. buffer when the size of the requested memory was small enough.  This
  701. has been changed to just use new because of concerns in a multi-
  702. threaded environment.
  703.  
  704. A non-standard class has been added: template <class T> class 
  705. _TempVec.  This creates an array of T by using get_temporary_buffer,
  706. and initializes it with a user supplied value.  The for reason this 
  707. class is to facilitate the use of get_temporary_buffer in an 
  708. exception-safe manner.  This class is used in <algorithm>.
  709.  
  710. There is a new auto_ptr in the Nov' 97 standard (which unfortunately
  711. is not public).  The best public information I know of on this 
  712. subject can be found at http://www.dejanews.com/ (search for auto_ptr).  
  713. The main change in auto_ptr is that when the class relenquishes 
  714. ownership of its pointer, it sets itself to null.  The Dec. '96 
  715. auto_ptr has been left in <memory>, but commented out.  If you require 
  716. the '96 behavior, then simply comment out the '97 version, and 
  717. uncomment the '96 version.
  718.  
  719. The Pro4 compiler does not support member template operators.  
  720. Therefore the Nov. '97 auto_ptr retains its pre-member-template code 
  721. even with member templates enabled in the lib.  This will prevent
  722. conversions between auto_ptr<X> and auto_ptr<Y>.
  723.  
  724. The '97 auto_ptr does not provide a way to assign a temporary 
  725. (or const) auto_ptr to an existing one.  We believe that this is an
  726. oversight in the C++ standard.  Therefore we have added the following 
  727. non-standard member to auto_ptr:
  728.  
  729.     auto_ptr& operator=(auto_ptr_ref r) throw();
  730.  
  731.  
  732. <new>
  733. -----
  734.  
  735. References to DebugNew have been deleted.  This does not imply a lack
  736. of support for this utility.  Indeed, look forward to increased
  737. support in this area!
  738.  
  739. <ostream>
  740. ---------
  741.  
  742. A default constructor was added to aid in the construction of the
  743. standard streams in a non-leaking manner.
  744.  
  745. Corrected the basic_istream constructor which takes a streambuf
  746. pointer.  This not only made the class more standard, but corrected a
  747. problem with user-defined classes derived from istream.
  748.  
  749. Formatting of char output has been corrected (now obeys width and
  750. justification).
  751.  
  752. Output of char* has been rewritten to take advantage of the new
  753. locale.  There is however, no change in functionality.
  754.  
  755. The exception behavior of the formatted output operators has been
  756. modified.  Unfortunately a bug still lurks here.  If an exception is
  757. thrown, then the method should set badbit and rethrow the exception.
  758. Instead, badbit is left unset.  This is a known bug and will be fixed
  759. in the next release.
  760.  
  761. <string>
  762. --------
  763.  
  764. Fixed a bug in char_traits<char>::find related to char's greater than
  765. 127.
  766.  
  767. Removed default argument from
  768. iterator string::insert(iterator, char)
  769. per the standard.
  770.  
  771. Changed string output to respect stream width and justification.
  772. This is non-standard behavior, but I believe that the standard is in
  773. error (a type-o of a single word: smaller was written when larger meant).
  774. If the standard is strictly interpreted, then os << string;
  775. should produce no output at all!  (That is, for the common case of
  776. os.width() == 0).
  777.  
  778. Fixed a potential crasher where string was overwriting the end of its
  779. allocated memory under certain resize calls.
  780.  
  781. <strstream>
  782. -----------
  783.  
  784. The header <strstream> defines three types that associate stream 
  785. buffers with character array objects and assist reading and 
  786. writing such objects.
  787.  
  788. This header is deprecated, where deprecated is defined as: Normative 
  789. for the current edition of the Standard, but not guaranteed to be
  790. part of the Standard in future revisions.
  791.  
  792. <vector>
  793. --------
  794.  
  795. Reduced inline depth of several iterator operations.
  796.  
  797. ===================================================================
  798. *  MSL C Source File Updates 
  799. ===================================================================
  800.    
  801. *  Removed #pragma direct_destruction from the following C headers: 
  802.    console.h, csetjmp, fcntl.mac.h, fcntl.win32.h, SIOUX.h, 
  803.    stat.mac.h, stat.win32.h, unistd.mac.h, unistd.win32.h,
  804.    unix.mac.h, unix.win32.h, utime.mac.h, utime.win32.h, utsname.h 
  805.    This will not be supported in future versions of the compiler.
  806.        
  807. *  C compiler flags have moved from <ansi_parms.h> to
  808.    <ansi_prefix.xxx.h>, where xxx is mac or Win32.
  809.  
  810. *  ansi_files.c
  811.    Change to allow error-free linking in case where _No_Console is 
  812.    defined.  MW07076, MW06847
  813.    
  814. *  ansi_parms.h 
  815.    C compiler flags have moved from <ansi_parms.h> to 
  816.    <ansi_prefix.xxx.h>, where xxx is mac or Win32.
  817.    
  818. *  alloca.h
  819.    Added to 68K platforms.  (MacOS Support folder)
  820.    
  821. *  console_io.mac.c
  822.    SIOUX.h
  823.    SIOUX.c
  824.    Changes to implement clrscr, for which there was a declaration 
  825.    in console.h but no code.
  826.    
  827. *  cinttypes
  828.    inttypes.h
  829.    New C9X headers added to MSL.
  830.    
  831. *  eof.h
  832.    New header to define EOF.  Needed to prevent circular includes
  833.    for cstdio and cwctypes.
  834.    
  835. *  fcntl.mac.h
  836.    fcntl.mac.c
  837.    fcntl.win32.h
  838.    Changes to the value of O_RDWR so that it has a non-zero value.  
  839.    MW00042.
  840.    
  841. *  fcntl.win32.h
  842.    fnctl.win32.c
  843.    Changes to remove #defines of open, creat, fcntl to _open, 
  844.    _creat, and _fcntl.
  845.    
  846. *  file_io.c
  847.    The C Standard does not specify any action for fflush() on a 
  848.    stream opened for read only.  As it stood, our implementation  
  849.    caused the buffer to be reloaded.  This change turns fflush()
  850.    into a no-op if the file is opened for read.  MW02733
  851.  
  852. *  file_io.mac.c
  853.    path2fss.c
  854.    Changes to allow the renaming of directories. MW00456
  855.    
  856. *  file_io.mac.c
  857.    Change to allow an alias file name to be resolved.  MW00294
  858.  
  859. *  math.h
  860.    This header has been brought closer to the C9X standard.  On 68K, 
  861.    the standard math functions can now be called through a function 
  862.    pointer.  Additionally, support has been added for the "f" and 
  863.    "l" versions of each function (which currently simply redirect 
  864.    to the double versions) on all platforms.  These can be called 
  865.    through function pointers as well.  
  866.    
  867.    float sqrtf(float);
  868.    double sqrt(double);
  869.    long double sqrtl(long double);
  870.  
  871.    In C, for the "f" and "l" functions that simply redirect to the 
  872.    double version, #defines are used to avoid overhead.  However these 
  873.    functions can still be called through function pointers (with an 
  874.    overhead expense).  In C++, none of the functions are implemented 
  875.    via a #define.  Instead inline functions are used so that all 
  876.    functions obey namespace rules.
  877.  
  878.    On PPC, the "l" functions redirect to the double versions instead 
  879.    of using the Apple supplied 128-bit versions since the CodeWarrior 
  880.    long double is 64 bits.
  881.  
  882.    On Windows, the "f" and "l" redirection functions are not exported 
  883.    from DLL versions of the MSL C library.  This is a known problem 
  884.    and will be fixed in the next release.
  885.    
  886. *  mem.c
  887.    Change to allow memchr to work on the PPC for characters of 
  888.    value > 127.  MW02625
  889.  
  890. *  scanf.c
  891.    Modification to allow characters >= 128, e.g. fl or ä to be matched 
  892.    from format string correctly. MW06720
  893.  
  894. *  SIOUX.c
  895.    Fix to insert linefeed to make the sequence \b\n work correctly.
  896.  
  897.    Fix the enter key work as return on input from keyboards where 
  898.    the virtual key code is 0x34 as well for keyboards with an enter 
  899.    key virtual key code of 0x4c. MW06775
  900.    
  901. *  string.c
  902.    Fixed a bug with non-Standard behavior when a NULL pointer is
  903.    passed in as the pattern - we now return str.  A copy of
  904.    string.c.faster is included as a "thrill seeker" for PPC users.
  905.    This speeds up string handling on the PPC platform, but hasn't
  906.    been fully validated in time for the release for desktop PPC
  907.    platforms.
  908.    
  909. *  string.win32.c
  910.    Fix a bug in strcmp and strncmp in which string compares did
  911.    not work property when there were bytes in the range of 
  912.    128...255 (i.e., -128...-1) signed
  913.  
  914. *  SIOUXWindows.c
  915.    Removed two ReleaseResource statements that released a shared 
  916.    resource, causing possible crashes in other applications. 
  917.    MW00225
  918.  
  919. *  unistd.mac.c
  920.    Fix to lseek for case where it is used to seek beyond EOF to 
  921.    extend the file.  MW00445  (I don't believe lseek implemented 
  922.    on Windows yet.)
  923.  
  924. *  time.c
  925.    Corrected strftime to return the correct number of characters 
  926.    written and make proper check to avoid target string overrun. 
  927.    MW06496
  928.  
  929. *  SIOUXGlobals.c
  930.    SIOUXGlobals.h
  931.    Changes to make SIOUX_WASTE work properly for files greater 
  932.    than 32k.  MW07031
  933.  
  934. *  utime.win32.h
  935.    Change to reintroduce #include <winsock.h> eliminated earlier. 
  936.    This include is required and has been requested again from a 
  937.    user.  However, this leads to redeclaration warning messages 
  938.    during the building of the library due to the way that the 
  939.    Microsoft headers (which we can't change) have been written. 
  940.  
  941. *  unistd.win32.h
  942.    unistd.win32.c
  943.    Changes to revert _lseek, _read, _write, _access, _close, 
  944.    _unlink, _rmdir, _chdir, _getcwd to lseek, read, write, access, 
  945.    close etc. while accommodating legacy code.
  946.  
  947.  
  948. ===================================================================
  949. *  WinSIOUX
  950. ===================================================================
  951.  
  952.    The Mac SIOUX-like project is now available for Windows.  This 
  953.    means that a new console window for WIN32 applications is 
  954.    available that permits saving stdout to a file, printing it from 
  955.    a menu option, and includes scroll bar.  A new stationary on the 
  956.    windows platforms is included, named WinSIOUX.  You will not get 
  957.    the standard DOS/NT console if you use this stationary.  The 
  958.    remaining functions from SIOUX will be included in future releases 
  959.    (for example, cut and paste, selecting font, and opening/closing 
  960.    files from the menu).
  961.   
  962. *  clrscr() has been added to WinSIOUX.  Please include WinSIOUX.h in
  963.    your application to get this functionality.
  964.  
  965. *  Also added is a fixed bound on the size of the WinSIOUX buffer to 
  966.    32768 bytes.  Attempts to store bytes beyond that amount leads to
  967.    program termination, though the user does have the opportunity to 
  968.    save the 32768 bytes that are in the buffer before terminating the 
  969.    application.
  970.    
  971. *  Please ensure that Winspool.lib is included in your WinSIOUX
  972.    project.
  973.     
  974. *  The addition of an Edit Menu with active items of Copy, Cut
  975.    Paste and Select All.
  976.     
  977. *  Keyboard shortcuts for menu items.  Note that, during keyboard
  978.    input to stdin or cin, the keyboard shortcuts are not available
  979.    and the corresponding menu items must be used.
  980.  
  981. *  Caret control both through the keyboard (arrow keys) and the
  982.    mouse.
  983.     
  984. *  The ability to select parts of the file with the mouse.
  985.  
  986. *  The ability to print just specific pages selected during the
  987.    print dialog.
  988.     
  989. *  During keyboard input to stdin or cin, ctrl+D and ctrl+Z both
  990.    serve as end-of-file markers.  There is no way to clear this
  991.    marker once it has been set.
  992.     
  993. *  While the program is running, Ctrl-C acts as a keyboard interrupt
  994.    that can be handled by a user specified handler.  If no handler 
  995.    is provided by the user, the default handler will terminate the
  996.    program.  When there parts of the file have been selected with
  997.    the mouse, Ctrl-C still acts as a keyboard shortcut for Copy.
  998.     
  999. *  Added proper handling of argv and argc variable length argument
  1000.    lists.
  1001.     
  1002. *  The size of the console window can now be adjusted with the mouse 
  1003.    in  the bottom right corner and the display of long lines of text 
  1004.    will be adjusted accordingly.
  1005.  
  1006.    
  1007.  
  1008. ===================================================================   
  1009. Miscellaneous Notes
  1010. ===================================================================
  1011.  
  1012. *  Compiling Pascal targets on the Mac
  1013.    Rebuld the Win32Headers, then rebuild the Pascal libraries.  You 
  1014.    must then places the libraries into the appropriate folders as
  1015.    noted in the "How To" file.  This only applies to Mac builds - 
  1016.    the Win32 builds on the x86 hosts are fine.  We will make sure 
  1017.    this is fixed in the final release of Pro4.
  1018.    
  1019. *  Compiling Win32 targets
  1020.    
  1021.    When building the ANSICx86.lib and ANSICx86D.lib with the 
  1022.    MSL C.Win32.mcp or MSL C.PPC.MTrgt.mcp project linker warnings  
  1023.    for previous defined symbols will be generated.  These warnings  
  1024.    are expected and can safely be ignored.
  1025.  
  1026.    MacOS only:  The aforementioned linker warnings will appear as 
  1027.    errors when using the Build MSL Libraries utility.  Furthermore 
  1028.    the build library process will halt until the error is 
  1029.    acknowledged; these  "errors" can be safely ignored.   
  1030.   
  1031. *  Precompiled header stationary sets precompiled headers to 4i-8d.  
  1032.    When using precompiled headers built from the stationary, please 
  1033.    ensure that the libraries you include in your project are also 
  1034.    4i-8d. If changing the precompiled headers preferences panels, 
  1035.    please ensure that you build the associated libraries you plan 
  1036.    to use with the same options.  A "#pragma check_header_flags" 
  1037.    has been added to MSL.pch++ to help check for these types of 
  1038.    errors. 
  1039.    
  1040. *  Improved clock for Mac platforms
  1041.    To increase the tick count for the Mac platforms in order to use 
  1042.    the facilities the Operating System provides, please change the 
  1043.    following file:  
  1044.        Metrowerks Standard Library/MSL C/MSL Mac/Public Includes/
  1045.               timesize.mac.h
  1046.    This file introduces a define (__TIMESIZE_DOUBLE) which enables 
  1047.    the improved clock code in time.h and time.mac.c.  Please note 
  1048.    that the clock_t typedef will change from an unsigned long to a 
  1049.    type double. This also means that the clock function will change 
  1050.    types.  Be sure you confirm in your code base that your return 
  1051.    values are typed accordingly for clock and clock_t.
  1052.    
  1053. *  Multi-target project files.  You will see new project files with 
  1054.    the string MTrg included in the project name.  This means that 
  1055.    the project file can emit all targets from that single file, 
  1056.    depending on your selection when you open the project file and 
  1057.    choose a target.  However, it takes more time to open the multi-
  1058.    target project files.  This was done for the windows platforms 
  1059.    because scripting is not available in the IDE on windows. 
  1060.  
  1061. *  Console applications for windows projects now stop before exiting 
  1062.    so that output can be viewed.  This feature can be turned off by 
  1063.    setting the preprocessor macro STOP_PROGRAM_BEFORE_EXIT in the
  1064.    windows prefix file, ansi_prefix.win32.h.  Be sure to rebuild
  1065.    MSL C after making this change.  Please note that if you redirect 
  1066.    output to a serial device (such as a printer), you must still 
  1067.    press enter to  exit the program. 
  1068.    
  1069. *  There is a vbscript script in the "Metrowerks Standard Library" 
  1070.    directory that rebuilds the precompiled header files, the win32 
  1071.    runtime, and all MSL libraries.  Read the information at the top 
  1072.    of the script file "msl_build.vbs" if you have problems running 
  1073.    the script.  The file "msl_list" in the same directory can be 
  1074.    configured to build exactly those libraries you wish to build.  
  1075.    If errors occur while building, they are logged in the file 
  1076.    "error.log" in the "Metrowerks Standard Library" directory. 
  1077.  
  1078.  
  1079. ========================================================================
  1080. Contacting Metrowerks
  1081. ========================================================================
  1082.  
  1083. For bug reports, technical questions, and suggestions, please use the
  1084. forms in the Release Notes folder on the CD, and send them to
  1085.  
  1086. support@metrowerks.com
  1087.  
  1088. See the CodeWarrior on the Nets document in the Release Notes folder for
  1089. more contact information, including a list of Internet newsgroups, 
  1090. online services, and patch and update sites.
  1091.  
  1092. ========================================================================
  1093.  
  1094. Metrowerks Corporation
  1095.